#include "stdafx.h"
/// Copyright 2012, Alex Averian, Yonan Research
/// Released under BSD Licence

#include "qresource.h"

#include "directx/qwic.h"
using namespace micro::directx;




using namespace micro::app;



// Loads the PNG containing the res

HBITMAP QResource::LoadResImage( UINT res, LPCTSTR type   )
{
    return LoadResImage( MAKEINTRESOURCE( res ), type   );
}

HBITMAP QResource::LoadResImage( LPCTSTR res, LPCTSTR type )
{
    HBITMAP bitmap = nullptr;

    HRESULT hr  = QWic::CreateBitmapFromResource( res,  type, bitmap );

    return bitmap;
}